﻿using System;
using System.Linq;

namespace encrpt
{
   public class Decrypt
    {
        private string original;
        public Decrypt()
        {
            original = "";
        }
        public Decrypt(string eOriginal)
        {
            string temp = eOriginal.Aggregate(String.Empty, (current, t) => current + (char)(t ^ 25));
            original = temp;
        }
        public Decrypt(Decrypt eOriginal)
        {
            Original = eOriginal.Original;
        }
        public Decrypt(Encrypt eOriginal)
        {
            Original=DeCrypt(eOriginal.Password);
        }
        public string Original
        {
            get { return original; }
            set { original = value; }
        }
        public static string DeCrypt(string original)
        {
            return original.Aggregate(String.Empty, (current, t) => current + (char)(t ^ 25));
        }
    }
}
